package org.order.server.service;

import org.order.server.service.fallback.FeignConfiguration;
import org.order.server.service.fallback.GoodServiceFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@FeignClient(name = "alibaba-cloud-good-server", fallback = GoodServiceFallback.class,
        configuration = FeignConfiguration.class)
public interface GoodService {

    /**
     * 查询商品信息
     *
     * @param code
     * @return
     */
    @GetMapping("/good/{code}")
    String queryGood(@PathVariable String code);
}
